<script setup>
import { computed } from 'vue'

// 顶部安全区高度
const { safeAreaInsets: { bottom: tabBarSafeBottom } } = uni.getSystemInfoSync()

// 导航栏总高度
const totalTabBarHeight = computed(() => tabBarSafeBottom + 50)
</script>

<template>
  <footer :style="{ height: `${totalTabBarHeight}px` }">
    <view
      class="bg-white fixed h-[50px] w-full bottom-0 left-0 z-100"
      :style="{ paddingBottom: `${tabBarSafeBottom}px` }"
    >
      <slot />
    </view>
  </footer>
</template>
